import { IMessageBase } from "../../Framework/MQ/IMessageBase";
import { MessageManager } from "../../Framework/MQ/MessageManager";
import { SerializeStream } from "../../Framework/Serialize/SerializeStream";
type int = number;
//class SPanicBuyItemMsg
    
    export  class SPanicBuyItemMsg extends IMessageBase
    {
        constructor(arg1: Boolean=false)
        {
            
            super();if (arg1) 
            {
                MessageManager.instance().regist(this);
            }
            return;
        }

        public /* override */ getType(): int
        {
            return this._type;
        }

        public /* override */ clone(): IMessageBase
        {
            return new SPanicBuyItemMsg();
        }

        public /* override */ __write(arg1: SerializeStream): void
        {
            arg1.writeInt(this.type);
            arg1.writeInt(this.itemCode);
            arg1.writeInt(this.price);
            arg1.writeInt(this.discount);
            arg1.writeInt(this.buyLimit);
            arg1.writeInt(this.leftAmount);
            return;
        }

        public /* override */ __read(arg1: SerializeStream): void
        {
            this.type = arg1.readInt();
            this.itemCode = arg1.readInt();
            this.price = arg1.readInt();
            this.discount = arg1.readInt();
            this.buyLimit = arg1.readInt();
            this.leftAmount = arg1.readInt();
            return;
        }

        public /* const */_type: int=12030;

        public /* var */type: int;

        public /* var */itemCode: int;

        public /* var */price: int;

        public /* var */discount: int;

        public /* var */buyLimit: int;

        public /* var */leftAmount: int;

        public static /* var */_regist: SPanicBuyItemMsg;
    }

            SPanicBuyItemMsg._regist = new SPanicBuyItemMsg(true);
        